package org.example.data;

import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
import com.fasterxml.jackson.annotation.JsonProperty;

import java.util.Map;

//@JsonIgnoreProperties(ignoreUnknown = true)
public class Fence
{
    @JsonProperty("id")
    private Integer id;  // 标签所在的电子围栏id

    @JsonProperty("name")
    private String name;  // 标签所在的电子围栏名称

    @JsonProperty("userData")
    private Map<String, Object> userData;  // 用户自定义数据

    // 无参构造函数
    public Fence() {}

    // Getter和Setter方法
    public Integer getId() {
        return id;
    }

    public void setId(Integer id) {
        this.id = id;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public Map<String, Object> getUserData() {
        return userData;
    }

    public void setUserData(Map<String, Object> userData) {
        this.userData = userData;
    }

    @Override
    public String toString() {
        return "Fence{" +
                "id=" + id +
                ", name='" + name + '\'' +
                ", userData=" + userData +
                '}';
    }
}
